/**
 * Created with Intellij IDEA
 * Description
 * User:ASUS
 * Date:2024-08-01
 * Time:17:49
 */
public class Test {
    public static void eat(Animal a){
        a.eat();
    }

    public static void main(String[] args) {
        Cat cat=new Cat("小黄",6);
        Dog dog=new Dog("小黑",5);
        eat(cat);
        eat(dog);
    }
}
